<?php
class ActivityConf_formatExcelData {
	function formatExcelData($dataArr, $typeId, $allType = 'all') {
		$newDataArr = array();
		foreach ($dataArr as $key => $val) {
			foreach ($val as $k => $v) {
				if($dataArr[0][$k] == $typeId || $dataArr[0][$k] == $allType) {
					$newDataArr[$key][$k] = $v;
				}
			}
		}
		unset($newDataArr[0]);
		return $newDataArr;
	}
}